package com.intelligentclass.repositories;

import com.intelligentclass.entity.Collection;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface CollectionRepository extends JpaRepository<Collection, Integer> {
    // 可以在这里添加自定义查询方法
    boolean existsByCollectionCommentIdAndCollectionSno(int collectionCommentId, String collectionSno);
    List<Collection> findByCollectionSno(String collectionSno);

    Collection findByCollectionCommentIdAndCollectionSno(int commentId, String sno);
}